package com.act.moudles.baseAct.entity;

import java.util.Date;

import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.extension.activerecord.Model;
import lombok.Data;
import org.apache.commons.lang3.StringUtils;

import java.io.Serializable;

/**
 * (OnlineDeployRecords)表实体类
 *
 * @author makejava
 * @since 2023-05-09 21:56:07
 */
@SuppressWarnings("serial")
@Data
@TableName("s_online_deploy_records")
public class OnlineDeployRecords  {
    //组建
    @TableId
    private Long reId;
    //关联id
    private Long deId;
    //创建者
    private Long createBy;
    //创建时间
    private Date createTime;
    //备注
    private String remark;
    //定义Id
    private String procdefId;
    //定义key
    private String procdefKey;
    //用户调用key
    private String userProcdefKey;

    //关联id
    private Long userId;
    //多租户标识
    private String tenantId;

    //部署名称
    private String depeloyName;
    //定义描述
    private String procdefDes;
    //解析结果
    private String anlRes;
    //bpmn文件路径
    private String bpmnPath;
    //图片路径
    private String pngPath;

    private String bpmnFileName;

    private Long userOrgId;

    private String userName;

    public LambdaQueryWrapper<OnlineDeployRecords> query(){
        LambdaQueryWrapper<OnlineDeployRecords> query = new LambdaQueryWrapper<>();
        query.like(StringUtils.isNotEmpty(depeloyName),OnlineDeployRecords::getDepeloyName,depeloyName);
        query.like(StringUtils.isNotEmpty(userProcdefKey),OnlineDeployRecords::getUserProcdefKey,userProcdefKey);
        query.like(deId != null,OnlineDeployRecords::getDeId,deId);
        return query;
    }

}

